﻿using System;
using System.Collections.Generic;
using System.Text;

namespace IceDog.DNL.CSharp.DesignPattern.ProxyPattern.ImageLibrary
{
    public class RealImage:IImageAction
    {
        private readonly string _fileName;
        
        /// <summary>
        /// 
        /// </summary>
        /// <param name="fileName"></param>
        public RealImage(string fileName)
        {
            _fileName = fileName;
            LoadFromDisk(fileName);
        }
        public void Display()
        {
            Console.WriteLine($"文件名 : {_fileName}");
        }

        private void LoadFromDisk(string fileName)
        {
            Console.WriteLine($"加载文件: {fileName}");
        }
    }
}
